import Vue from 'vue'
import VueRouter from 'vue-router'

Vue.use(VueRouter)

const routes = [
  {
    path: '',
    redirect: '/areatop'
  },
  {
    path: '/areatop',
    component: () => import('../pages/AreaTopPage.vue')
  },
  {
    path: '/harvets',
    component: () => import('../pages/Harvest')
  },
  {
    path: '/proportion',
    component: () => import('../pages/Proportion')
  },
  {
    path: '/cover',
    component: () => import('../pages/CropCoveragePage')
  },
  {
    path: '/trend',
    component: () => import('../pages/CropGrowthTrend')
  },
  {
    path: '/toarlarea',
    component: () => import('../pages/TotalArea')
  },
  {
    path: '/summary',
    component: () => import('../pages/Summary')
  }
]

const router = new VueRouter({
  mode: 'history',
  base: process.env.BASE_URL,
  routes
})

export default router
